package com.gz.service;

import com.gz.entity.Vo.CartItemVo;
import com.gz.entity.Vo.CartVo;

public interface CartService {
    /**
     * 获取用户的购物车
     */
    CartVo getCart(Long userId);

    /**
     * 添加一件商品到购物车
     */
    CartVo addCartItem(CartItemVo cartItemVo);

    /**
     * 删除购物车项
     */
    CartVo removeCartItem(Long userId, Long bookId);

    void updateCart(Long bookId, Integer quantity, Long id);

    void deleteCartItem(Long bookId, Long id);

    CartVo  clearCart(Long userId);

    void deleteCart(Long userId);
}
